package com.yzd.netmonitor.page;

import java.io.Serializable;
import java.util.List;

public class PageDataBean<T> implements Serializable {

	private static final long serialVersionUID = -4804408682752372155L;
	/**
	 * 总数
	 */
	private int count = 0;
	
	/**
	 * 数据
	 */
	private List<T> data;
	
	/**
	 * 每页显示数量
	 */
	private int pageSize;

	public int getCount() {

		return count;
	}

	public void setCount(int count) {

		this.count = count;
	}

	public List<T> getData() {

		return data;
	}

	public void setData(List<T> data) {

		this.data = data;
	}
	
	/**
	 * 返回总数
	 * @return
	 */
	public long getTotalPage() {
		return this.count % this.pageSize == 0 ? this.count / this.pageSize : this.count / this.pageSize + 1;
	}
}
